<script setup lang="ts">
import { ElMessage } from 'element-plus'

export interface Data {
  name: string
  code: string
}

export interface areaData {
  province: Data
  city: Data
  area: Data
}

let changeArea = (val: areaData) => {
  ElMessage.success(`${val.province.name}-${val.city.name}-${val.area.name}`)
}
</script>

<template>
  <m-choose-area @change="changeArea"></m-choose-area>
</template>

<style lang="scss" scoped></style>
